package com.onedec.designer.entity;

import java.util.ArrayList;
import java.util.List;

public class OnedecPlanExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public OnedecPlanExample() {
        oredCriteria = new ArrayList<>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andPlanIdIsNull() {
            addCriterion("plan_id is null");
            return (Criteria) this;
        }

        public Criteria andPlanIdIsNotNull() {
            addCriterion("plan_id is not null");
            return (Criteria) this;
        }

        public Criteria andPlanIdEqualTo(Integer value) {
            addCriterion("plan_id =", value, "planId");
            return (Criteria) this;
        }

        public Criteria andPlanIdNotEqualTo(Integer value) {
            addCriterion("plan_id <>", value, "planId");
            return (Criteria) this;
        }

        public Criteria andPlanIdGreaterThan(Integer value) {
            addCriterion("plan_id >", value, "planId");
            return (Criteria) this;
        }

        public Criteria andPlanIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("plan_id >=", value, "planId");
            return (Criteria) this;
        }

        public Criteria andPlanIdLessThan(Integer value) {
            addCriterion("plan_id <", value, "planId");
            return (Criteria) this;
        }

        public Criteria andPlanIdLessThanOrEqualTo(Integer value) {
            addCriterion("plan_id <=", value, "planId");
            return (Criteria) this;
        }

        public Criteria andPlanIdIn(List<Integer> values) {
            addCriterion("plan_id in", values, "planId");
            return (Criteria) this;
        }

        public Criteria andPlanIdNotIn(List<Integer> values) {
            addCriterion("plan_id not in", values, "planId");
            return (Criteria) this;
        }

        public Criteria andPlanIdBetween(Integer value1, Integer value2) {
            addCriterion("plan_id between", value1, value2, "planId");
            return (Criteria) this;
        }

        public Criteria andPlanIdNotBetween(Integer value1, Integer value2) {
            addCriterion("plan_id not between", value1, value2, "planId");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdIsNull() {
            addCriterion("plan_project_id is null");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdIsNotNull() {
            addCriterion("plan_project_id is not null");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdEqualTo(Integer value) {
            addCriterion("plan_project_id =", value, "planProjectId");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdNotEqualTo(Integer value) {
            addCriterion("plan_project_id <>", value, "planProjectId");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdGreaterThan(Integer value) {
            addCriterion("plan_project_id >", value, "planProjectId");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("plan_project_id >=", value, "planProjectId");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdLessThan(Integer value) {
            addCriterion("plan_project_id <", value, "planProjectId");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdLessThanOrEqualTo(Integer value) {
            addCriterion("plan_project_id <=", value, "planProjectId");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdIn(List<Integer> values) {
            addCriterion("plan_project_id in", values, "planProjectId");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdNotIn(List<Integer> values) {
            addCriterion("plan_project_id not in", values, "planProjectId");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdBetween(Integer value1, Integer value2) {
            addCriterion("plan_project_id between", value1, value2, "planProjectId");
            return (Criteria) this;
        }

        public Criteria andPlanProjectIdNotBetween(Integer value1, Integer value2) {
            addCriterion("plan_project_id not between", value1, value2, "planProjectId");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperIsNull() {
            addCriterion("plan_design_paper is null");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperIsNotNull() {
            addCriterion("plan_design_paper is not null");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperEqualTo(String value) {
            addCriterion("plan_design_paper =", value, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperNotEqualTo(String value) {
            addCriterion("plan_design_paper <>", value, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperGreaterThan(String value) {
            addCriterion("plan_design_paper >", value, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperGreaterThanOrEqualTo(String value) {
            addCriterion("plan_design_paper >=", value, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperLessThan(String value) {
            addCriterion("plan_design_paper <", value, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperLessThanOrEqualTo(String value) {
            addCriterion("plan_design_paper <=", value, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperLike(String value) {
            addCriterion("plan_design_paper like", value, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperNotLike(String value) {
            addCriterion("plan_design_paper not like", value, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperIn(List<String> values) {
            addCriterion("plan_design_paper in", values, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperNotIn(List<String> values) {
            addCriterion("plan_design_paper not in", values, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperBetween(String value1, String value2) {
            addCriterion("plan_design_paper between", value1, value2, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanDesignPaperNotBetween(String value1, String value2) {
            addCriterion("plan_design_paper not between", value1, value2, "planDesignPaper");
            return (Criteria) this;
        }

        public Criteria andPlanStatusIsNull() {
            addCriterion("plan_status is null");
            return (Criteria) this;
        }

        public Criteria andPlanStatusIsNotNull() {
            addCriterion("plan_status is not null");
            return (Criteria) this;
        }

        public Criteria andPlanStatusEqualTo(String value) {
            addCriterion("plan_status =", value, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanStatusNotEqualTo(String value) {
            addCriterion("plan_status <>", value, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanStatusGreaterThan(String value) {
            addCriterion("plan_status >", value, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanStatusGreaterThanOrEqualTo(String value) {
            addCriterion("plan_status >=", value, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanStatusLessThan(String value) {
            addCriterion("plan_status <", value, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanStatusLessThanOrEqualTo(String value) {
            addCriterion("plan_status <=", value, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanStatusLike(String value) {
            addCriterion("plan_status like", value, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanStatusNotLike(String value) {
            addCriterion("plan_status not like", value, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanStatusIn(List<String> values) {
            addCriterion("plan_status in", values, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanStatusNotIn(List<String> values) {
            addCriterion("plan_status not in", values, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanStatusBetween(String value1, String value2) {
            addCriterion("plan_status between", value1, value2, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanStatusNotBetween(String value1, String value2) {
            addCriterion("plan_status not between", value1, value2, "planStatus");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2IsNull() {
            addCriterion("plan_plan2 is null");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2IsNotNull() {
            addCriterion("plan_plan2 is not null");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2EqualTo(String value) {
            addCriterion("plan_plan2 =", value, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2NotEqualTo(String value) {
            addCriterion("plan_plan2 <>", value, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2GreaterThan(String value) {
            addCriterion("plan_plan2 >", value, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2GreaterThanOrEqualTo(String value) {
            addCriterion("plan_plan2 >=", value, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2LessThan(String value) {
            addCriterion("plan_plan2 <", value, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2LessThanOrEqualTo(String value) {
            addCriterion("plan_plan2 <=", value, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2Like(String value) {
            addCriterion("plan_plan2 like", value, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2NotLike(String value) {
            addCriterion("plan_plan2 not like", value, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2In(List<String> values) {
            addCriterion("plan_plan2 in", values, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2NotIn(List<String> values) {
            addCriterion("plan_plan2 not in", values, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2Between(String value1, String value2) {
            addCriterion("plan_plan2 between", value1, value2, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan2NotBetween(String value1, String value2) {
            addCriterion("plan_plan2 not between", value1, value2, "planPlan2");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3IsNull() {
            addCriterion("plan_plan3 is null");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3IsNotNull() {
            addCriterion("plan_plan3 is not null");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3EqualTo(String value) {
            addCriterion("plan_plan3 =", value, "planPlan3");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3NotEqualTo(String value) {
            addCriterion("plan_plan3 <>", value, "planPlan3");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3GreaterThan(String value) {
            addCriterion("plan_plan3 >", value, "planPlan3");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3GreaterThanOrEqualTo(String value) {
            addCriterion("plan_plan3 >=", value, "planPlan3");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3LessThan(String value) {
            addCriterion("plan_plan3 <", value, "planPlan3");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3LessThanOrEqualTo(String value) {
            addCriterion("plan_plan3 <=", value, "planPlan3");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3Like(String value) {
            addCriterion("plan_plan3 like", value, "planPlan3");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3NotLike(String value) {
            addCriterion("plan_plan3 not like", value, "planPlan3");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3In(List<String> values) {
            addCriterion("plan_plan3 in", values, "planPlan3");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3NotIn(List<String> values) {
            addCriterion("plan_plan3 not in", values, "planPlan3");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3Between(String value1, String value2) {
            addCriterion("plan_plan3 between", value1, value2, "planPlan3");
            return (Criteria) this;
        }

        public Criteria andPlanPlan3NotBetween(String value1, String value2) {
            addCriterion("plan_plan3 not between", value1, value2, "planPlan3");
            return (Criteria) this;
        }
    }

    /**
     *
     */
    public static class Criteria extends GeneratedCriteria {
        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}